package com.zhijian.wharf.dao;

import com.zhijian.wharf.entity.po.AutomaticControl;
import com.zhijian.wharf.entity.vo.request.AutomaticControlSearchVo;
import com.zhijian.wharf.entity.vo.response.AutomaticControlVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface AutomaticControlMapper {
    int deleteByPrimaryKey(Long id);

    int insert(AutomaticControl record);

    int insertSelective(AutomaticControl record);

    AutomaticControl selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(AutomaticControl record);

    int updateByPrimaryKey(AutomaticControl record);

    /**
     * 查询总数
     *
     * @param automaticControlSearchVo
     * @return
     */
    int count(AutomaticControlSearchVo automaticControlSearchVo);

    /**
     * 查询列表
     *
     * @param automaticControlSearchVo
     * @return
     */
    List<AutomaticControlVo> selectList(AutomaticControlSearchVo automaticControlSearchVo);

    /**
     * 查询单个
     *
     * @param automaticControlSearchVo
     * @return
     */
    AutomaticControlVo selectOne(AutomaticControlSearchVo automaticControlSearchVo);

    /**
     * 根据ID查询vo
     *
     * @param id
     * @return
     */
    AutomaticControlVo selectVoById(Long id);

    /**
     * 批量删除
     *
     * @param idList
     * @return
     */
    void deleteByIdList(@Param("idList") List<Long> idList);

    /**
     * 动态删除
     *
     * @param automaticControlSearchVo
     * @return
     */
    void deleteByCondition(AutomaticControlSearchVo automaticControlSearchVo);

    /**
     * 批量新增
     *
     * @param entities
     * @return
     */
    int insertBatch(@Param("entities") List<AutomaticControl> entities);
}